import request from '@/utils/request'
import type { IRouteResponseModel } from '@/model/routesModel'

enum ROUTER_API_URL {
  GET_ROUTERS_URL = '/system/menu/getRouters',
}

/**
 * 获取路由
 * @returns Promise<IRouteResponseModel>
 */
export const getRouters = (): Promise<IRouteResponseModel> => {
  return request.get<any, IRouteResponseModel>(ROUTER_API_URL.GET_ROUTERS_URL)
}
